package com.ypy.event;

import org.springframework.util.Assert;

public class PayLoadApplicationEvent<T> extends ApplicationEvent {
    private final T payload;

    public PayLoadApplicationEvent(Object source, T payload) {
        super(source);
        Assert.notNull(payload, "Payload must not be null");
        this.payload = payload;
    }

    public T getPayload() {
        return this.payload;
    }
}
